package com.neo.util;

import java.io.IOException;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * Created by admin on 2017/12/15.
 *
 */
public class ErrorFileUtil {
    public static Map<String,String> handle(List<String> errData, String fileName){
        Map<String,String> result = new HashMap<>();
        try {
            DjsStringUtil.writeStringToFile(errData,"",fileName);
            result.put("handleCount", errData.size()+"");
            result.put("result", "success");
            result.put("message","处理成功");
            result.put("fileName",fileName);
        } catch (IOException e) {
            e.printStackTrace();
            result.put("result", "error");
            result.put("message","" + e.getMessage());
        }
        return result;
    }
}
